//
//  SWBaseFilter.swift
//  ChildStory
//
//  Created by linhan on 16/8/29.
//  Copyright © 2016年 Aiya. All rights reserved.
//

import Foundation
import UIKit

protocol SWFilterDelegate:NSObjectProtocol
{
    func filterProcessCompletion(_ filter:SWBaseFilter, image:UIImage, info:[String:Any]?)
    func filterProcessFail(_ filter:SWBaseFilter, error:NSError)
}

class SWBaseFilter:NSObject
{
    weak var delegate:SWFilterDelegate?
    
    weak var image:UIImage?
    weak var thumb:UIImage?
    
    static let SkinSmoothImageKey:String = "SkinSmoothImage"
    
    var name:String{
        return "滤镜"
    }
    
    func execute(image:UIImage, info:[String:Any]?)
    {
        
    }
    
    func execute(image:UIImage, info:[String:Any]?, successCallback:@escaping ((UIImage)->Void), failCallback:((NSError)->Void)?)
    {
        
    }
    
    //滤镜不在使用后，进行清理
    func dispose()
    {
        
    }
    
}
